home *** CD-ROM | disk | FTP | other *** search
- /************************************************************
- Include file CProtect
-
- ⌐ Thomas Lichtneckert 1995
- Nordenski÷ldsgatan 24
- S-413 09 G÷teborg
- Sweden
- fax: +46 - 31 121 621
- voice: +46 - 31 145 131
- email: Thomas.Lichtneckert@abc.se
- ************************************************************/
-
- #ifndef _CPROTECT_
- #define _CPROTECT_
-
- #include <windows.h>
-
- #ifndef __INTSIZE
- #if defined(__SMALL__) && __I86__ > 2
- #define __INTSIZE 4
- #else
- #define __INTSIZE 2
- #endif
- #endif
-
- #if __INTSIZE == 2
- typedef long INT32;
- typedef unsigned long UINT32;
- typedef short INT16;
- typedef unsigned short UINT16;
- #elif ( __INTSIZE == 4)
- typedef int INT32;
- typedef unsigned int UINT32;
- typedef short INT16;
- typedef unsigned short UINT16;
- #endif
-
- #define FILE_NOT_FOUND -10
- #define PATH_NOT_VALID -11
- #define NO_PATH -12
- #define NOT_REMOVABLE -13
- #define DRIVE_OK 0
- #define NO_ARGUMENTS 1
- #define DRIVE_NOT_FLOPPY 2
- #define DRIVE_NOT_READY 3
- #define DRIVE_NOT_VALID 4
- #define DRIVE_ERROR 5
- #define WRONG_DISKETTE 6
- #define DRIVE_WRPROT 7
- #define DRIVE_WRPROT_A 8
- #define DRIVE_WRPROT_B 9
- #define DISK_ISIN_A 10
- #define DISK_ISIN_B 11
- #define NOT_REGISTERED 20
- #define NO_REGINFO 21
- #define NO_SERNUMBER 22
- #define FEATURES_NOT_AVAILABLE 23
- #define WRONG_CODE 24
- #define IS_REGISTERED 748
-
- #define WINAPI _far _pascal
-
- #if __cplusplus
- extern "C" {
- #endif
- /* cpMakeRegCode should be commented out when using cprot20u.dll */
- INT16 WINAPI cpMakeRegCode( INT16 features, char * serialnum, char * regcode );
-
- INT16 WINAPI cpCFGMake( char * path, UINT32 magic, UINT32 filever );
- INT16 WINAPI cpGetSernum( char* path, char * serialnum );
- INT16 WINAPI cpRegisterProgram( char * path, char * regcode );
- INT16 WINAPI cpCheckRegCode( char * path, char * regcode );
- INT16 WINAPI cpGetRegisteredName( char* path, char * namn );
- INT16 WINAPI cpGetRegisteredCompany( char * path, char * namn);
- INT16 WINAPI cpSetRegisteredNames( char * path, char * namn, char * firma );
- INT16 WINAPI cpIsRegistered( char * path );
- INT16 WINAPI cpGetUParams( char* path, UINT32 *paraml, INT16 *param1, INT16 *param2, INT16 *param3, INT16 *param4, UINT16 *param5 );
- INT16 WINAPI cpSetUParams( char* path, UINT32 paraml, INT16 param1, INT16 param2, INT16 param3, INT16 param4, UINT16 param5 );
- INT16 WINAPI cpSetFTime( char * path, UINT32 datum, UINT16 tid );
- INT16 WINAPI cpWhichDrive( char * fil );
- INT16 WINAPI cpDirRemove( char * path );
- INT16 WINAPI cpStartProgram( char * path );
- INT16 WINAPI cpEndProgram( char * path );
- INT16 WINAPI cpGetUStatistics( char * path, UINT16 * antggr, UINT16 *stim, UINT16 *smin, UINT16 *ssek, UINT16 *atim, UINT16 *amin, UINT16 *asek );
- INT32 WINAPI cpGetFileinfo( char * path, INT32 * version );
-
- #if __cplusplus
- }
- #endif
- #endif /* _CPROTECT_ */
-